import moment from 'moment'
import employees from '../utils/constant/employess'
import store from '../store/index'
export const trunHireType = function (value) {
  const bool = employees.hireType.find(item => {
    return item.id === value
  })
  return bool ? bool.value : ''
}

export const timeformat = function (value) {
  return moment(value).format('YYYY-MM-DD')
}

export const btnper = function (value) {
  return store.getters.userInfo.roles.points.includes(value)
}

export const btndelete = function (value) {
  return store.getters.userInfo.roles.points.includes(value)
}
